Skip to content

Conversation

@ElfSundae
Copy link
Contributor

This pull request fixes the missing padding in example code blocks introduced by changes in PHP 8.3+.
Since highlight_string() now returns <pre><code>...</code></pre> instead of <code>...</code>, the existing CSS rule targeting only <code> no longer applied.

截屏2025-10-09 19 46 40

The fix adds <pre> to the selector so both cases are covered:

+.docs .example-contents > .phpcode > pre,
 .docs .example-contents > .phpcode > code {
     padding: .75rem;
 }

This ensures that the padding style is correctly applied to all example code blocks.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 11, 2025

🚀 Regression report for commit 9799963 is at https://web-php-regression-report-pr-1501.preview.thephp.foundation

@github-actions
Copy link
Contributor

github-actions bot commented Nov 11, 2025

🚀 Preview for commit 9799963 can be found at https://web-php-pr-1501.preview.thephp.foundation

Co-authored-by: Luffy <52o@qq52o.cn>
@sy-records sy-records merged commit 0c0d93a into php:master Nov 13, 2025
4 of 5 checks passed
@sy-records
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants